import { notification } from 'antd'
// 封装 Notification

// 显示成功通知
const showSuccess = (message, description) => {
  notification.success({
    message: message || 'Success',
    description: description || 'This is the content of the notification.',
    duration: 4 // 默认持续时间
  })
}
// 显示错误通知
const showError = (message, description) => {
  notification.error({
    message: message || 'Error',
    description: description || 'This is the content of the error notification.',
    duration: 4 // 默认持续时间
  })
}
// 显示警告通知
const showWarning = (message, description) => {
  notification.warning({
    message: message || 'Warning',
    description: description || 'This is the content of the warning notification.',
    duration: 4 // 默认持续时间
  })
}
// 显示信息通知
const showInfo = (message, description) => {
  notification.info({
    message: message || 'Info',
    description: description || 'This is the content of the information notification.',
    duration: 4 // 默认持续时间
  })
}
export { showError, showInfo, showSuccess, showWarning }
